package com.panshi.servers.impl;

import com.panshi.api.bean.AnswerAuditHDBean;
import com.panshi.api.util.PageSizeVO;
import com.panshi.mapper.AnswerAuditHDMapper;
import com.panshi.pojo.AnswerAuditHDVO;
import com.panshi.servers.AnswerAuditHDServers;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author XiaoWangYa
 * @version 1.0
 * @date 2020/8/10 0010 上午 10:40
 */
@Service
@Api("回答未审核Servers层")
public class AnswerAuditHDServersImpl implements AnswerAuditHDServers {

    @Autowired
    private AnswerAuditHDMapper answerAuditHDMapper;

    @Override   // 新增回答审核数据
    public void addAnswerAuditHDInfo(AnswerAuditHDBean answerAuditHDBean) {
        answerAuditHDMapper.addAnswerAuditHDInfo(answerAuditHDBean);
    }

    @Override   // 删除回答审核数据
    public void deleteAnswerAuditHDInfo(int id) {
        answerAuditHDMapper.deleteAnswerAuditHDInfo(id);
    }

    @Override   // 查询指定问答下未审核回答 and 指定用户回答未审核数据
    public List<AnswerAuditHDVO> queryAssignAuditHDQuestionAnswerInfo(PageSizeVO pageSizeHDBean) {
        return answerAuditHDMapper.queryAssignAuditHDQuestionAnswerInfo(pageSizeHDBean);
    }

    @Override   // 修改回答审核
    public void updateAnswerAuditHDInfo(AnswerAuditHDBean answerAuditHDBean) {
        answerAuditHDMapper.updateAnswerAuditHDInfo(answerAuditHDBean);
    }
}
